package com.itec.learn.java.design.observer.jive;

/**
 * @author chenyiqun
 */
public class Main {

    public static void main(String[] args) {
        ForumFactory factory = new ForumFactory();

        ForumThread thread = new ForumThread("测试","Jive",factory);
        User user1 = new User("AAA");
        User user2 = new User("BBB");
        User user3 = new User("CCC");

        factory.watchManager.createWatch(user1,thread);
        factory.watchManager.createWatch(user2,thread);
        factory.watchManager.createWatch(user3,thread);

        thread.addMessage("回复111");

    }

}
